<div class='head'>
  <div class='title'>
    »  中国移动飞信
  </div>
  <div class='help'>

  </div>
  <div class='tools'>
    <%= link_to_remote "✎绑定",
          :update => 'fetion',
          :url => edit_fetion_user_url(current_user),
          :method => :get,
          :loading => small_loading('edit_fetion_link',:only_img => true),
          :html => {
          :class => :h,
          :id => 'edit_fetion_link'
        } %>
</div>
  </div>
<div id='fetion_body'>
  <table width="700" cellspacing="4" cellpadding="3" border="0">
    <tbody>
      <tr>
        <td class="t px12" width="100">手机号</td>
        <td class="px12" >
          <% if current_user.mobile.blank? %>
            <b class='alert'>未绑定</b>
          <% else %>
            <b><%= current_user.mobile %></b>
            <% if current_user.fetion_version.lite? %>            
              <% if current_user.lite_fetion_status.wait? %>
              <%= link_to_function "等待您的绑定回复中...", "$('edit_fetion_link').onclick()" , :title => "尚未收到您同意加飞信机器人【#{current_user.fetion.name}-#{current_user.fetion.mobile}】的确认消息哦，再试试？",:class => :alert %>
              <% else %>
              与<b class='h' title='飞信机器人【<%= current_user.fetion.name %>-<%= current_user.fetion.mobile %>】负责您的短信业务'><%= current_user.fetion.name %></b> 成功绑定！
              <% end %>
            <% else %>
            <%= link_to_function '接口升级，请重新绑定飞信：）',"$('edit_fetion_link').onclick()", :title => '由于移动与2010年11月20日对旧版本的飞信（2008）进行了限制，麦吐司无法将短信发送到您手机。麦吐司及时对飞信接口进行了升级，需要您重新绑定，绑定过程不在需要您提供飞信密码了，赶快把：）', :class => :alert %>
            <% end %>
          <% end %>
        </td>
      </tr>
    </tbody>
  </table>
  <table width="700" cellspacing="4" cellpadding="3" border="0">
    <tbody>
      <tr>
        <td colspan="2">
          <div class="help">
            <div>
              <%= link_to "为什么要绑定飞信号？", helps_url(:id => 4), :target => :_blank %>
            </div>
            <div>
              <%= link_to "如何开通飞信服务？", helps_url(:id => 5), :target => :_blank %>
            </div>
            <div>
              <%= link_to "绑定不了？请联系管理员#{'<img border="0" align="absmiddle" alt="QQ在线交谈" src="http://wpa.qq.com/pa?p=1:7861848:4">'}", "tencent://message/?uin=7861848&amp;Site=www.mytusi.com&amp;Menu=yes", :target => :_blank %>
            </div>
            <div>
              <%= link_to "会泄露我的个人信息吗？", helps_url(:id => 9), :target => :_blank %>
            </div>
          </div>
        </td>
      </tr>
      <tr>
        <td colspan='2'>
          <dl id="binded_feeds">
            <dt>最近都有谁绑定了飞信：</dt>
            <% Feed::MoneyFetion.all(:order => 'created_at desc', :limit => 20).each_with_index do |feed, index| %>
            <dd class='feed' style='<%= index == 0 ? '' : 'display:none' %>'><%= feed_to_html feed %></dd>
            <% end %>
          </dl>
          <script type="text/javascript" charset="utf-8">
            setInterval("next_feed('binded_feeds')",5000);
          </script>
        </td>
      </tr>
    </tbody>
  </table>
</div>  